<?php


namespace app\common\models;


use app\common\traits\BaseModelOptionTrait;
use think\Model;
use think\model\concern\SoftDelete;

class Share extends Model
{
    use BaseModelOptionTrait, SoftDelete;

    protected $table = 'xiangji_shares';



    protected $autoWriteTimestamp = true;

    protected $defaultSoftDelete = 0;

    protected $deleteTime = 'delete_time';

    public function setDataAttr($value)
    {
        return serialize($value);
    }
    public function getDataAttr($value)
    {
        if (!$value) return '';
        return unserialize($value);
    }
}
